package com.hxzy.demo.Study0927;

import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.ListView;

import com.hxzy.demo.R;

/**
 * Created by Yang on 2016/9/27.
 */
public class TestWonderMomentActivity extends AppCompatActivity {
    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.fragment_wonder_monent);
        ListView lv = (ListView) findViewById(R.id.wonder_moment_lv);
        BaseAdapter baseAdapter = new BaseAdapter() {
            @Override
            public int getCount() {
                return 20;
            }

            @Override
            public Object getItem(int position) {
                return null;
            }

            @Override
            public long getItemId(int position) {
                return 0;
            }

            @Override
            public View getView(int position, View convertView, ViewGroup parent) {
                View itemView = View.inflate(parent.getContext(),R.layout.item_wonder_moment_lv,null);
                return itemView;
            }
        };
        lv.setAdapter(baseAdapter);
    }
}
